import { StrictMode } from 'react';
import { createRoot } from 'react-dom/client';
import App from './App.jsx';
import '@/assets/styles/rest.scss';
import { Provider } from 'react-redux';
import store from './store/index.js';
import { BrowserRouter } from 'react-router-dom';
import { ConfigProvider } from 'antd';
import zhCN from 'antd/locale/zh_CN';
import createVersionPolling from '@/utils/checkVersion';
createRoot(document.getElementById('root')).render(
	<Provider store={store}>
		<ConfigProvider locale={zhCN}>
			<BrowserRouter>
				<App />
			</BrowserRouter>
		</ConfigProvider>
	</Provider>
);
console.log(import.meta.env.VITE_APP_API_BASE);
// import.meta.env.MODE != 'dev' &&
// 	createVersionPolling({
// 		onUpdated: () => {
// 			console.log('有新版本，正在刷新页面');
// 		},
// 	});
